package main

import (
	"bigbackend/routers"
	"bigbackend/utils"
	"github.com/gin-contrib/cors"
	"github.com/gin-gonic/gin"
)

func main() {
	utils.InitMongoClient()
	r := gin.Default()
	r.Use(cors.Default())
	r.Static("/assets", "./assets")
	routers.AdminRoute(r)
	routers.CarsRoute(r)
	if err := r.Run(":3000"); err != nil {
		panic("Error！")
	}
}
